import Vue from "vue";
// import VueRouter from "vue-router";
import VueRouter from "../Vue-Router";
import Index from "../views/Index.vue";

Vue.use(VueRouter);

/**
 * @type { import('vue-router').RouteConfig[] }
 */
const routes = [
  {
    path: "/",
    name: "Index",
    component: Index,
  },
  {
    path: "/blog",
    name: "Blog",
    component: () => import("../views/Blog.vue"),
  },
  {
    path: "/photo",
    name: "Photo",
    component: () => import("../views/Photo.vue"),
  },
  {
    path: '*',
    name: '404',
    component: () => import('../views/404.vue')
  }
];

/**
 * @type { import('vue-router').RouterOptions }
 */
const routerOptions = {
  routes,
  mode: "hash",
};

const router = new VueRouter(routerOptions);

export default router;
